package vista;
import java.awt.BorderLayout;
import javax.swing.JButton;

import javax.swing.JFrame;
import javax.swing.JOptionPane;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JTable;



import controlador.ContActualizarIngredientes;


/**
* This code was edited or generated using CloudGarden's Jigloo
* SWT/Swing GUI Builder, which is free for non-commercial
* use. If Jigloo is being used commercially (ie, by a corporation,
* company or business for any purpose whatever) then you
* should purchase a license for each developer using Jigloo.
* Please visit www.cloudgarden.com for details.
* Use of Jigloo implies acceptance of these licensing terms.
* A COMMERCIAL LICENSE HAS NOT BEEN PURCHASED FOR
* THIS MACHINE, SO JIGLOO OR THIS CODE CANNOT BE USED
* LEGALLY FOR ANY CORPORATE OR COMMERCIAL PURPOSE.
*/
public class DlgActualizarIngredientes extends javax.swing.JDialog {
	private JPanel pnlIngredientes;
	private JScrollPane jScrollPane1;
	private JButton btSalir;
	private JButton btModificar;
	private JButton btAnadir;
	private JTable tblIngredientes;

	/**
	* Auto-generated main method to display this JDialog
	*/
	private ContActualizarIngredientes controlador;

	public DlgActualizarIngredientes(JFrame frame, ContActualizarIngredientes controlador) {
		super(frame);
		this.controlador = controlador;
		initGUI();
	}
	
	

	
	private void initGUI() {
		try {
			{
				this.setTitle("Ingredientes");
			}
			{
				pnlIngredientes = new JPanel();
				getContentPane().add(pnlIngredientes, BorderLayout.CENTER);
				pnlIngredientes.setPreferredSize(new java.awt.Dimension(373, 278));
				pnlIngredientes.setLayout(null);
				
				{
					jScrollPane1 = new JScrollPane();
					pnlIngredientes.add(jScrollPane1);
					jScrollPane1.setBounds(38, 22, 296, 133);
					{
						
						tblIngredientes = new JTable();
						jScrollPane1.setViewportView(tblIngredientes);

						tblIngredientes.setBounds(90, 74, 193, 63);
					}
				}
				{
					btAnadir = new JButton();
					pnlIngredientes.add(btAnadir);
					btAnadir.setText("Agregar");
					btAnadir.setBounds(38, 214, 97, 26);
				}
				{
					btModificar = new JButton();
					pnlIngredientes.add(btModificar);
					btModificar.setText("Modificar");
					btModificar.setBounds(150, 214, 110, 26);
				}
				{
					btSalir = new JButton();
					pnlIngredientes.add(btSalir);
					btSalir.setText("Salir");
					btSalir.setBounds(277, 214, 72, 26);
				}
			}
			this.setSize(380, 305);
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
	public void mostrarMensaje(String mensaje) {
		JOptionPane.showMessageDialog(this, mensaje);
	}
	
	public JTable getTblIngredientes() {
		return tblIngredientes;
	}

	public JButton getBtModificar() {
		return btModificar;
	}

	public JButton getBtSalir() {
		return btSalir;
	}

	public JButton getBtAnadir() {
		return btAnadir;
	}
}
